import { WeaTools } from 'ecCom'

export const getExecAssessData = params => {   // 获取团队画像执行力评测数据
    return WeaTools.callApi('/api/workrelate/portrait/teamWorkrelateInfo', 'GET', params)
}

export const getCurrUserinfo = params => {   // 获取当前用户信息
    return WeaTools.callApi('/api/workrelate/common/currUserinfo', 'GET', params)
}

export const getTeamRisk = params => {   // 获取团队风险信息
    return WeaTools.callApi('/api/workrelate/portrait/risk/getTeamRisk', 'GET', params)
}

export const getRiskDataByInterfaceinfo = params => {   // 根据interfaceinfo获取风险数据
    const interfaceinfo = params.interfaceinfo
    delete params.interfaceinfo
    return WeaTools.callApi(interfaceinfo, 'GET', params)
}

export const getInterfacesInfo = params => {   // 获取外部接口信息
    return WeaTools.callApi("/api/workrelate/portrait/interface/getList", 'GET', params)
}

export const getViewRight = params => {   // 获取目标机构视图权限
    return WeaTools.callApi("/api/workrelate/portrait/getViewRight", 'GET', params)
}